package com.key.win.business.chat.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.key.win.base.model.MybatisID;
import com.key.win.business.chat.eums.ImGroupStatusEnum;
import com.key.win.business.chat.eums.ImGroupTypeEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.HashSet;
import java.util.Set;

@ApiModel("群用户")
@Data
@TableName("im_group_user")
@EqualsAndHashCode(callSuper = true)
public class ImGroupUser extends MybatisID {
    @ApiModelProperty("用户ID")
    private String userId;
    @ApiModelProperty("组ID")
    private String groupId;
    @ApiModelProperty("群内用户昵称")
    private String name;

    @ApiModelProperty("用户列表")
    @TableField(exist = false)
    private Set<String> userIds = new HashSet<>();

    @ApiModelProperty("群类型")
    @TableField(exist = false)
    private ImGroupTypeEnum type;
    @ApiModelProperty("群状态")
    @TableField(exist = false)
    private ImGroupStatusEnum status;
}
